package common.fengkai.filepost;

import common.fengkai.filepost.service.impl.Boy;
import common.fengkai.filepost.service.impl.Girl;
import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.context.annotation.ComponentScan;


@Slf4j
@ComponentScan("common.fengkai.filepost.*")
@SpringBootApplication
public class PdfoutstreamApplication {

    public static void main (String[] args) {
        ConfigurableApplicationContext applicationContext = SpringApplication.run(PdfoutstreamApplication.class, args);
        log.info("启动成功");
        Boy boy = applicationContext.getBean("boy", Boy.class);
        Girl girl = applicationContext.getBean("girl", Girl.class);
        boy.buy();
        girl.buy();
        //    log.debug("hahahahah");
    }

}
